import Vue from "vue";
import App from "./App.vue";
import router from "./router";
import store from "./store";
// 引入vant
import Vant from "vant";
import "vant/lib/index.css";
import { setRem } from "./utils/rem";
// import { Dialog } from "vant";
import { Notify } from 'vant';
import { Toast } from 'vant';

setRem();

// onresize 回调数组
window.resizeCallbackList = [setRem];
window.onresize = () => {
  window.resizeCallbackList.map((callback) => {
    callback();
  });
};

Vue.use(Toast)
// 全局注册
Vue.use(Notify);
// // 全局注册
// Vue.use(Dialog);
Vue.use(Vant);
Vue.config.productionTip = false;

new Vue({
  router,
  store,
  render: (h) => h(App),
}).$mount("#app");
